using System.Collections.Generic;

namespace SmartMathLibrary.Geometry
{
    /// <summary>
    /// An interface to implement a Polygon3D.
    /// </summary>
    public interface IPolygon3D
    {
        /// <summary>
        /// Gets or sets the polygon data in form of a list.
        /// </summary>
        /// <value>The polygon data.</value>
        List<Point3D> PolygonData { get; set; }

        /// <summary>
        /// Adds a point to the polygon.
        /// </summary>
        /// <param name="point">The point to add.</param>
        void AddPoint(Point3D point);

        /// <summary>
        /// Gets the point at a specified position.
        /// </summary>
        /// <param name="index">The index of the point in the point list.</param>
        /// <returns>The point specified at the specified position.</returns>
        Point3D GetPoint(int index);

        /// <summary>
        /// Gets the number of points of the current polygon.
        /// </summary>
        /// <returns>The number of points of the current polygon.</returns>
        int GetNumberOfPoints();

        /// <summary>
        /// Deletes the point of the polygon.
        /// </summary>
        /// <param name="index">The index of the point which should be deleted.</param>
        void DeletePoint(int index);

        /// <summary>
        /// Scales the polygon with a specified factor.
        /// </summary>
        /// <param name="scaleFactor">The scale factor for x and y position.</param>
        void ScalePolygon(double scaleFactor);

        /// <summary>
        /// Scales the polygon with specified factors.
        /// </summary>
        /// <param name="scaleFactorX">The scale factor for the x position.</param>
        /// <param name="scaleFactorY">The scale factor for the y position.</param>
        /// <param name="scaleFactorZ">The scale factor for the z position.</param>
        void ScalePolygon(double scaleFactorX, double scaleFactorY, double scaleFactorZ);

        /// <summary>
        /// Translates the polygon with the specified parameters.
        /// </summary>
        /// <param name="translateValue">The value with which the polygon has to be translated.</param>
        void TranslatePolygon(double translateValue);

        /// <summary>
        /// Translates the polygon in x and y direction.
        /// </summary>
        /// <param name="translateValueX">The translation value for x the axis.</param>
        /// <param name="translateValueY">The translation value for y the axis.</param>
        /// <param name="translateValueZ">The translation value for z the axis.</param>
        void TranslatePolygon(double translateValueX, double translateValueY, double translateValueZ);

        /// <summary>
        /// Compares the current instance of a polygon with another polygon object. 
        /// </summary>
        /// <param name="compare">The line to compare.</param>
        /// <returns>True if the position of the polygons are even otherwise the method will 
        /// return false.</returns>
        bool CompareTo(Polygon3D compare);
    }
}